package com.ruoyi.system.service.impl;

import java.util.List;
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.TherapistEvaluationMapper;
import com.ruoyi.system.domain.TherapistEvaluation;
import com.ruoyi.system.service.ITherapistEvaluationService;

/**
 * 陪诊师评价Service业务层处理
 * 
 * @author ruoyi
 * @date 2025-06-09
 */
@Service
public class TherapistEvaluationServiceImpl implements ITherapistEvaluationService 
{
    @Autowired
    private TherapistEvaluationMapper therapistEvaluationMapper;

    /**
     * 查询陪诊师评价
     * 
     * @param id 陪诊师评价主键
     * @return 陪诊师评价
     */
    @Override
    public TherapistEvaluation selectTherapistEvaluationById(Long id)
    {
        return therapistEvaluationMapper.selectTherapistEvaluationById(id);
    }

    /**
     * 查询陪诊师评价列表
     * 
     * @param therapistEvaluation 陪诊师评价
     * @return 陪诊师评价
     */
    @Override
    public List<TherapistEvaluation> selectTherapistEvaluationList(TherapistEvaluation therapistEvaluation)
    {
        return therapistEvaluationMapper.selectTherapistEvaluationList(therapistEvaluation);
    }

    /**
     * 新增陪诊师评价
     * 
     * @param therapistEvaluation 陪诊师评价
     * @return 结果
     */
    @Override
    public int insertTherapistEvaluation(TherapistEvaluation therapistEvaluation)
    {
        therapistEvaluation.setCreateTime(DateUtils.getNowDate());
        return therapistEvaluationMapper.insertTherapistEvaluation(therapistEvaluation);
    }

    /**
     * 修改陪诊师评价
     * 
     * @param therapistEvaluation 陪诊师评价
     * @return 结果
     */
    @Override
    public int updateTherapistEvaluation(TherapistEvaluation therapistEvaluation)
    {
        therapistEvaluation.setUpdateTime(DateUtils.getNowDate());
        return therapistEvaluationMapper.updateTherapistEvaluation(therapistEvaluation);
    }

    /**
     * 批量删除陪诊师评价
     * 
     * @param ids 需要删除的陪诊师评价主键
     * @return 结果
     */
    @Override
    public int deleteTherapistEvaluationByIds(Long[] ids)
    {
        return therapistEvaluationMapper.deleteTherapistEvaluationByIds(ids);
    }

    /**
     * 删除陪诊师评价信息
     * 
     * @param id 陪诊师评价主键
     * @return 结果
     */
    @Override
    public int deleteTherapistEvaluationById(Long id)
    {
        return therapistEvaluationMapper.deleteTherapistEvaluationById(id);
    }
}
